#include <iostream>
#include <vector>

using std::cout;
using std::endl;
using std::vector;

void test0()
{
    vector<int> vec = {1, 3, 6, 8, 9, 5, 6};
    for(vector<int>::iterator it = vec.begin(); it != vec.end(); ++it)
    {
        cout << *it << "  ";
    }
    cout << endl;
}

void test()
{
    vector<int> vec = {1, 3, 6, 8, 9, 5, 6};
    for(vector<int>::reverse_iterator rit = vec.rbegin(); 
        rit != vec.rend(); ++rit)
    {
        cout << *rit << "  ";
    }
    cout << endl;
}

int main(int argc, char *argv[])
{
    test();
    return 0;
}

